package com.seu.dm.services;

import com.seu.dm.dto.SeckillEntryDTO;
import com.seu.dm.entities.Product;
import com.seu.dm.entities.Seckill;

import java.util.Date;
import java.util.List;

/**
 * Created by Greeting on 2017/3/20.
 */
public interface SeckillService {

    List<Seckill> queryAllWithProduct();

    Seckill queryByIdWithProduct(long seckillId);

    Seckill queryAvailableByIdAndStartTime(long seckillId,Date startTime);

    List<Seckill> queryAllStandByByStartTimeWithProduct(Date startTime);

    int insert(Seckill seckill);

    int update(Seckill seckill);

    int deleteById(long seckillId);

    int executeSeckill(long seckillId, Integer BuyerId);

    SeckillEntryDTO getSeckillEntry(long seckillId);

    Seckill getSeckillById(long seckillId);

    int publishSeckill(Seckill seckill, Product product);


}
